<!--{template "topic_header"}-->
<div class="main">  
  <div class="mainWrap Wrapbg">
  <div class="contentWrap">
	<!--以下站内短信导航部分-->
    {$left_menu}
	<!--以上站内短信导航部分-->
	
	<script type="text/javascript">
	 $(document).ready(function() {
			$("#add_atuser").click(function(){$("#showout_atuser").show();});
			$(".menu_hpb_c1").click(function(){$("#showout_atuser").hide();});
		 //表情
		 $(".menu_bqb_c").click(function(){
		 	$("#msg_showface").show();
		 	$(".menu_tqb").hide();
		 	$(".menu_fjb").hide();
		 });
		 //图片 
		 $(".menu_tqb_c").click(function(){
		 	$(".menu_tqb").show();
			$("#msg_showface").hide();
			$(".menu_fjb").hide();
		 });
		 $('#pubImg').click(function(){$("#publisher_file").style.posLeft=event.x-offsetWidth/2;$("#publisher_file").style.posTop=event.y-offsetHeight/2;});
		 $(".menu_tqb_c1").click(function(){$(".menu_tqb").hide();});
		 $("#publishSubmit").click(function(){$(".menu_tqb").hide();});
		 //附件 
		 $(".menu_fjb_c").click(function(){
		 	$(".menu_fjb").show();
		 	$(".menu_tqb").hide();
			$("#msg_showface").hide();
		 });
		 $('#pubAttach').click(function(){$("#publisher_file_attach").style.posLeft=event.x-offsetWidth/2;$("#publisher_file_attach").style.posTop=event.y-offsetHeight/2;});
		 $(".menu_fjb_c1").click(function(){$(".menu_fjb").hide();});
		 $("#publishSubmit").click(function(){$(".menu_fjb").hide();});
	 })
	 </script>
 
<style type="text/css">
.menu_fjb .arrow-up, .menu_fjb .arrow-up-in{ left:98px; top:-9px;}
.menuf_fj .menu_fjb_c1,.menuf_tq .menu_tqb_c1{position:absolute;top:5px;right:5px;}
.menu_hpb {left: 0;margin-top:-20px;}
.menu_hpb .showusr{width:380px;}
.showatuser p{margin-bottom:5px;}
.showatuser p input{width:350px;overflow:hidden;}
.showatuser .atleft{width:180px;border-right:1px solid #c5c5c5;margin-right:5px;padding-right:5px;float:left;margin-top:5px;overflow-x:hidden;height:320px;}
.showatuser .atright{float:left;width:180px;height:320px;overflow-x:hidden;}
.showatuser li img{width:30px;height:30px;vertical-align:middle;margin-right:5px;border:0px;}
.showatuser ul li{list-style:none;line-height:30px;padding:3px;}
.showatuser .atleft ul li{line-height:22px;}
.showatuser .active,.showatuser .curr{cursor:pointer;overflow:auto;zoom:1;background-color:#EEEFF6;}
.bhcolor{border:1px solid #f5b93c;}
.menu_hpb_c1 {width: 15px;height: 15px;background: url(templates/default/images/imgdel.gif) no-repeat;cursor: pointer;position: absolute;right: 5px;top: 5px;}
.menuf_bq{position: static;}
</style>     
     
    <div class="letterBox">
      <!--{if $this->Config['seccode_sms'] && $this->yxm_title}-->
	  <form action="{$action}" method="post" id='sendPM'>
	  <!--{else}-->
	  <form action="{$action}" method="post" onsubmit="return Validator.Validate(this,3);" id='sendPM'>
	  <!--{/if}-->
        <table width="100%" border="0" style="font-size:12px;">
          <tr>
            <td width="16%" align="right" valign="top">收件人：</td>
            <td width="84%" align="left" valign="middle">
              <input type="text"  name="to_user" id="to_user" value="{$to_user}" class="text-area" style="width:300px;"/>
			  <input id="add_atuser" type="button" class="btnText" value="添加收信人" onclick="showatuserw('to_user','pm','');return false;"/>
              <div class="pm_user_input" style="z-index:10;">
			    <div class="menu_hpb" id="showout_atuser">
                  <span class="arrow-up"></span><span class="arrow-up-in"></span>
			      <div class="menu_tb showusr">
                     <div id="showatuser_pm" class="showatuser"></div>
                     <sub class="menu_hpb_c1"></sub>
                  </div>
			    </div>				
			  </div>
			</td>
          </tr>
          <!--{if $buddy_list}-->
          <tr>
            <td align="right" valign="middle">好友群发：</td>
            <td align="left" valign="middle">
			<!--{loop $buddy_list $buddy}-->
              <input type="checkbox" style="border:none" name="buddy_list[{$buddy[touid]}]" value="{$buddy['nickname']}">
              <span title="{$buddy[description]}">{$buddy[nickname]}</span> &nbsp;
              <!--{/loop}-->            </td>
          </tr>
          <!--{/if}-->
          <tr>
            <td align="right" valign="top"><span valign="top">内容：</span></td>
            <td align="left" valign="middle"><textarea cols="45" rows="8" id="message" name="message" datatype="LimitB" min="1" msg="内容不能为空"  class="text-area">{$message}</textarea>            </td>
          </tr>
          <tr>
            <td align="left" valign="middle">&nbsp;</td>
            <td>
              <div class="comment_p_t2">
                <!--{if $this->Config['face_enable']}-->
                <div class="menuf_bq" id="editface"><b class="menu_bqb_c"><a href="javascript:void(0);" onclick="topic_face('msg_showface','message','topic_face');return false;" style="color:#666;">表情</a></b>
                   <div id="msg_showface" class="showface"></div>
                </div>
                <!--{/if}-->       
        
                <!--{if $this->Config['image_enable']}-->
                <div id="pm_image_uploadify" class="comment_p_b2 comment_p_b22">
                   <div class="menuf_tq" onclick="imageUploadifyHTML('', 'message', 'pm_image_uploadify', '1');"><b class="menu_tqb_c">图片</b></div>
                </div>
                <!--{/if}-->
                <!--{if $this->Config['attach_enable']}-->
                <div id="pm_attach_uploadify" class="comment_p_b2 comment_p_b22">
                   <div class="menuf_fj menu_fj_reply_style s" onclick="attachUploadifyHTML('', 'message', 'pm_attach_uploadify', '1', '', '0');"><b class="menu_fjb_c">附件</b></div>
                </div>
                <!--{/if}-->
            </div>
            <div style=" float:right">
               <label><input name="save_to_outbox" type="checkbox" id="outbox" value="1" style="border:none;">不发送，只保存到草稿箱中</label>
            </div>
          </td>
          </tr>
          <tr>
            <td align="left" valign="middle">&nbsp;</td>
            <td align="right" valign="middle">
			<!--{if $this->Config['seccode_sms'] && $this->yxm_title}-->
			<input type="button" class="btnText" value="发送" onclick="YXM_popBox(this,'sms1','{$this->yxm_title}');"/>
			<!--{else}-->
			<button type="submit" id="#submit" class="btnText" onclick="sendMsg(1); return false;">发送</button>
			<!--{/if}-->
			</td>
          </tr>
        </table>
      </form>
    </div>
    <!--{if $pm}-->
    <div style="border:1px solid #ccc;padding:5px;margin:5px;color:#484848;"><b>{$to_user}说:</b><br>
      {$pm[message]}</div>
    <!--{/if}-->
	
  </div>
  </div>
  <!--左边结束，右边开始-->
  <!--{template "topic_right.inc"}-->
</div>
<!--{template "topic_footer"}-->
